/*
 * @Author: anxia.ack anchenkai@come-future.com
 * @Date: 2025-04-13 20:33:32
 * @LastEditors: anxia.ack anchenkai@come-future.com
 * @LastEditTime: 2025-04-13 20:34:17
 * @FilePath: /free-learning-front/src/store/modules/courseType.ts
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import { getList, type CourseCategoryListVO } from '@/api/courseType';
import { defineStore } from 'pinia';

export const useCourseTypeStore = defineStore('courseType', {
  state: () => ({
    courseTypeList: [] as CourseCategoryListVO[],
  }),
  actions: {
    async getCourseTypeList() {
      const res = await getList();
      this.courseTypeList = res;
    },
  },
});
